		<%= render 'public/flash_notice' %>

  		<div id="module_win">
  			
  		</div>

  		<%= form_tag cpanel_users_path, method: 'get', :class => "form-search" do %>
  			<%= text_field_tag :search, params[:search],:placeholder => "输入用户呢称或者email" %>
  			<%= submit_tag "查找", :name => nil,  :class => 'btn' %>
  		<% end -%>

    	<table id="users" class="table table-striped">
    		<thead>
				<tr>
					<th><%= check_box_tag 'checkbox_all' %></th>
					<th>Email</th>
					<th>昵称</th>
					
					<th>创建时间</th>
					<th>最后更新时间</th>
					<th>状态</th>
					<td>操作</td>
				</tr>
			</thead>
			<tbody>
    		<% @users.each do |user| %>
    		
				<tr>
					<td><%= check_box_tag 'checkbox_name', user.id %></td>
					<td><%= user.email %></td>
					<td><%= user.nickname %></td>
					
					<td><%= format_datetime user.created_at,'%Y-%m-%d %H:%M' %></td>
					<td><%= format_datetime user.updated_at,'%Y-%m-%d %H:%M' %></td>
					<td>
						
					</td>
					<td>
						<%= link_to '重置密码'%>
						<%= link_to '删除', [:cpanel, user], confirm: '确认删除吗？', method: :delete %>
					</td>
				</tr>
			
    		<% end -%>
    		</tbody>
		</table>
		<div class="paginate-right-position">
			<%= will_paginate @users, :previous_label =>'上一页', :next_label => '下一页' %>
		</div>